home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 May: Tool Chest / Developer CD Series May 1996 (Tool Chest) (Apple Computer) (1996).iso / Tool Chest / Interfaces & Libraries / Interfaces / PInterfaces / Controls.p < prev    next >
Encoding:
Text File  |  1995-07-06  |  21.1 KB  |  678 lines  |  [TEXT/MPS ]

  1. {
  2.      File:        Controls.p
  3.  
  4.      Contains:    Control Manager interfaces
  5.  
  6.      Version:    Technology:    System 7.5
  7.                  Package:    Universal Interfaces 2.1 in “MPW Latest” on ETO #18
  8.  
  9.      Copyright:    © 1984-1995 by Apple Computer, Inc.
  10.                  All rights reserved.
  11.  
  12.      Bugs?:        If you find a problem with this file, use the Apple Bug Reporter
  13.                  stack.  Include the file and version information (from above)
  14.                  in the problem description and send to:
  15.                      Internet:    apple.bugs@applelink.apple.com
  16.                      AppleLink:    APPLE.BUGS
  17.  
  18. }
  19.  
  20. {$IFC UNDEFINED UsingIncludes}
  21. {$SETC UsingIncludes := 0}
  22. {$ENDC}
  23.  
  24. {$IFC NOT UsingIncludes}
  25.  UNIT Controls;
  26.  INTERFACE
  27. {$ENDC}
  28.  
  29. {$IFC UNDEFINED __CONTROLS__}
  30. {$SETC __CONTROLS__ := 1}
  31.  
  32. {$I+}
  33. {$SETC ControlsIncludes := UsingIncludes}
  34. {$SETC UsingIncludes := 1}
  35.  
  36.  
  37. {$IFC UNDEFINED __TYPES__}
  38. {$I Types.p}
  39. {$ENDC}
  40. {    ConditionalMacros.p                                            }
  41.  
  42. {$IFC UNDEFINED __QUICKDRAW__}
  43. {$I Quickdraw.p}
  44. {$ENDC}
  45. {    MixedMode.p                                                    }
  46. {    QuickdrawText.p                                                }
  47.  
  48. {$IFC UNDEFINED __MENUS__}
  49. {$I Menus.p}
  50. {$ENDC}
  51. {    Memory.p                                                    }
  52.  
  53. {$PUSH}
  54. {$ALIGN MAC68K}
  55. {$LibExport+}
  56. {$IFC UNDEFINED STRICT_CONTROLS }
  57. {$SETC STRICT_CONTROLS := 0}
  58. {$ENDC}
  59. {_________________________________________________________________________________________________________}
  60. {}
  61. { • CONTROL DEFINITION ID'S}
  62. {}
  63. {_________________________________________________________________________________________________________}
  64. {}
  65. { Standard System 7 procID's for use only with NewControl()}
  66. {}
  67.  
  68. CONST
  69.     pushButProc                    = 0;
  70.     checkBoxProc                = 1;
  71.     radioButProc                = 2;
  72.     scrollBarProc                = 16;
  73.     popupMenuProc                = 1008;
  74.  
  75.     kControlUsesOwningWindowsFontVariant = 1 * (2**(3));        { Control uses owning windows font to display text}
  76.  
  77. {_________________________________________________________________________________________________________}
  78. {}
  79. { • CONTROL PART CODES}
  80. {}
  81. {_________________________________________________________________________________________________________}
  82.     
  83. TYPE
  84.     ControlPartCode = SInt16;
  85.  
  86.  
  87. CONST
  88.     kControlNoPart                = 0;
  89.     kControlLabelPart            = 1;
  90.     kControlMenuPart            = 2;
  91.     kControlTrianglePart        = 4;
  92.     kControlButtonPart            = 10;
  93.     kControlCheckBoxPart        = 11;
  94.     kControlRadioButtonPart        = 11;
  95.     kControlUpButtonPart        = 20;
  96.     kControlDownButtonPart        = 21;
  97.     kControlPageUpPart            = 22;
  98.     kControlPageDownPart        = 23;
  99.     kControlIndicatorPart        = 129;
  100.     kControlDisabledPart        = 254;
  101.     kControlInactivePart        = 255;
  102.  
  103. {_________________________________________________________________________________________________________}
  104. {}
  105. { • CHECK BOX VALUES}
  106. {}
  107. {_________________________________________________________________________________________________________}
  108.     kControlCheckboxUncheckedValue = 0;
  109.     kControlCheckboxCheckedValue = 1;
  110.     kControlCheckboxMixedValue    = 2;
  111.  
  112. {_________________________________________________________________________________________________________}
  113. {}
  114. { • RADIO BUTTON VALUES}
  115. {}
  116. {_________________________________________________________________________________________________________}
  117.     kControlRadioButtonUncheckedValue = 0;
  118.     kControlRadioButtonCheckedValue = 1;
  119.     kControlRadioButtonMixedValue = 2;
  120.  
  121. {_________________________________________________________________________________________________________}
  122. { }
  123. { • CONTROL POP-UP MENU CONSTANTS}
  124. {}
  125. {_________________________________________________________________________________________________________}
  126. {}
  127. { Variant codes for the System 7 pop-up menu}
  128. {}
  129.     popupFixedWidth                = 1 * (2**(0));
  130.     popupVariableWidth            = 1 * (2**(1));
  131.     popupUseAddResMenu            = 1 * (2**(2));
  132.     popupUseWFont                = 1 * (2**(3));
  133.  
  134. {}
  135. { Menu label styles for the System 7 pop-up menu }
  136. {}
  137.     popupTitleBold                = 1 * (2**(8));
  138.     popupTitleItalic            = 1 * (2**(9));
  139.     popupTitleUnderline            = 1 * (2**(10));
  140.     popupTitleOutline            = 1 * (2**(11));
  141.     popupTitleShadow            = 1 * (2**(12));
  142.     popupTitleCondense            = 1 * (2**(13));
  143.     popupTitleExtend            = 1 * (2**(14));
  144.     popupTitleNoStyle            = 1 * (2**(15));
  145.  
  146. {}
  147. { Menu label justifications for the System 7 pop-up menu}
  148. {}
  149.     popupTitleLeftJust            = $00000000;
  150.     popupTitleCenterJust        = $00000001;
  151.     popupTitleRightJust            = $000000FF;
  152.  
  153. {_________________________________________________________________________________________________________}
  154. {}
  155. { • CONTROL DRAGGRAYRGN CONSTANTS}
  156. {}
  157. {   For DragGrayRgnUPP used in TrackControl() }
  158. {}
  159. {_________________________________________________________________________________________________________}
  160.     noConstraint                = kNoConstraint;
  161.     hAxisOnly                    = 1;
  162.     vAxisOnly                    = 2;
  163.  
  164. {_________________________________________________________________________________________________________}
  165. {}
  166. { • CONTROL COLOR TABLE PART CODES}
  167. {}
  168. {_________________________________________________________________________________________________________}
  169.     cFrameColor                    = 0;
  170.     cBodyColor                    = 1;
  171.     cTextColor                    = 2;
  172.     cThumbColor                    = 3;
  173.  
  174. {_________________________________________________________________________________________________________}
  175. {}
  176. { • CONTROL TYPE DECLARATIONS}
  177. {}
  178. {_________________________________________________________________________________________________________}
  179. {}
  180. { Define ControlRef and ControlHandle}
  181. {}
  182. {$IFC STRICT_CONTROLS }
  183.     
  184. TYPE
  185.     ControlRef = Ptr;
  186.  
  187.     ControlHandle = ControlRef;
  188.  
  189. {$ELSEC}
  190.     
  191. TYPE
  192.     ControlPtr = ^ControlRecord;
  193.     ControlHandle = ^ControlPtr;
  194.  
  195.     ControlRef = ControlHandle;
  196.  
  197. {$ENDC}
  198. {_________________________________________________________________________________________________________}
  199. {}
  200. { • CONTROL ACTIONPROC POINTER}
  201. {}
  202. {_________________________________________________________________________________________________________}
  203.     ControlActionProcPtr = ProcPtr;  { PROCEDURE ControlAction(theControl: ControlRef; partCode: ControlPartCode); }
  204.     ControlActionUPP = UniversalProcPtr;
  205.  
  206. {_________________________________________________________________________________________________________}
  207. {}
  208. { • CONTROL COLOR TABLE STRUCTURE}
  209. {}
  210. {_________________________________________________________________________________________________________}
  211.     CtlCTab = RECORD
  212.         ccSeed:                    SInt32;
  213.         ccRider:                SInt16;
  214.         ctSize:                    SInt16;
  215.         ctTable:                ARRAY [0..3] OF ColorSpec;
  216.     END;
  217.  
  218.     CCTabPtr = ^CtlCTab;
  219.     CCTabHandle = ^CCTabPtr;
  220.  
  221. {$IFC NOT STRICT_CONTROLS }
  222. {_________________________________________________________________________________________________________}
  223. {}
  224. { • CONTROL RECORD STRUCTURE}
  225. {}
  226. {_________________________________________________________________________________________________________}
  227.     ControlRecord = PACKED RECORD
  228.         nextControl:            ControlRef;
  229.         contrlOwner:            WindowRef;
  230.         contrlRect:                Rect;
  231.         contrlVis:                UInt8;
  232.         contrlHilite:            UInt8;
  233.         contrlValue:            SInt16;
  234.         contrlMin:                SInt16;
  235.         contrlMax:                SInt16;
  236.         contrlDefProc:            Handle;
  237.         contrlData:                Handle;
  238.         contrlAction:            ControlActionUPP;
  239.         contrlRfCon:            SInt32;
  240.         contrlTitle:            Str255;
  241.     END;
  242.  
  243. {_________________________________________________________________________________________________________}
  244. {}
  245. { • AUXILLARY CONTROL RECORD STRUCTURE}
  246. {}
  247. {_________________________________________________________________________________________________________}
  248.     AuxCtlRec = RECORD
  249.         acNext:                    Handle;
  250.         acOwner:                ControlRef;
  251.         acCTable:                CCTabHandle;
  252.         acFlags:                SInt16;
  253.         acReserved:                SInt32;
  254.         acRefCon:                SInt32;
  255.     END;
  256.  
  257.     AuxCtlPtr = ^AuxCtlRec;
  258.     AuxCtlHandle = ^AuxCtlPtr;
  259.  
  260. {_________________________________________________________________________________________________________}
  261. {}
  262. { • POP-UP MENU PRIVATE DATA STRUCTURE}
  263. {}
  264. {_________________________________________________________________________________________________________}
  265.     PopupPrivateData = RECORD
  266.         mHandle:                MenuHandle;
  267.         mID:                    SInt16;
  268.     END;
  269.  
  270.     PopupPrivateDataPtr = ^PopupPrivateData;
  271.     PopupPrivateDataHandle = ^PopupPrivateDataPtr;
  272.  
  273. {$ENDC}
  274.  
  275. CONST
  276.     uppControlActionProcInfo = $000002C0; { PROCEDURE (4 byte param, 2 byte param); }
  277.  
  278. FUNCTION NewControlActionProc(userRoutine: ControlActionProcPtr): ControlActionUPP;
  279.     {$IFC NOT GENERATINGCFM }
  280.     INLINE $2E9F;
  281.     {$ENDC}
  282.  
  283. PROCEDURE CallControlActionProc(theControl: ControlRef; partCode: ControlPartCode; userRoutine: ControlActionUPP);
  284.     {$IFC NOT GENERATINGCFM}
  285.     INLINE $205F, $4E90;
  286.     {$ENDC}
  287. {_________________________________________________________________________________________________________}
  288. {    }
  289. { • CONTROL CREATION / DELETION API'S}
  290. {}
  291. {_________________________________________________________________________________________________________}
  292.  
  293. FUNCTION NewControl(theWindow: WindowRef; {CONST}VAR boundsRect: Rect; title: ConstStr255Param; visible: BOOLEAN; value: SInt16; min: SInt16; max: SInt16; procID: SInt16; refCon: SInt32): ControlRef;
  294.     {$IFC NOT GENERATINGCFM}
  295.     INLINE $A954;
  296.     {$ENDC}
  297. FUNCTION GetNewControl(controlID: SInt16; owner: WindowRef): ControlRef;
  298.     {$IFC NOT GENERATINGCFM}
  299.     INLINE $A9BE;
  300.     {$ENDC}
  301. PROCEDURE DisposeControl(theControl: ControlRef);
  302.     {$IFC NOT GENERATINGCFM}
  303.     INLINE $A955;
  304.     {$ENDC}
  305. PROCEDURE KillControls(theWindow: WindowRef);
  306.     {$IFC NOT GENERATINGCFM}
  307.     INLINE $A956;
  308.     {$ENDC}
  309. {_________________________________________________________________________________________________________}
  310. {    }
  311. { • CONTROL SHOWING/HIDING API'S}
  312. {}
  313. {_________________________________________________________________________________________________________}
  314. PROCEDURE ShowControl(theControl: ControlRef);
  315.     {$IFC NOT GENERATINGCFM}
  316.     INLINE $A957;
  317.     {$ENDC}
  318. PROCEDURE HideControl(theControl: ControlRef);
  319.     {$IFC NOT GENERATINGCFM}
  320.     INLINE $A958;
  321.     {$ENDC}
  322. {_________________________________________________________________________________________________________}
  323. {    }
  324. { • CONTROL DRAWING API'S}
  325. {}
  326. {_________________________________________________________________________________________________________}
  327. PROCEDURE DrawControls(theWindow: WindowRef);
  328.     {$IFC NOT GENERATINGCFM}
  329.     INLINE $A969;
  330.     {$ENDC}
  331. PROCEDURE Draw1Control(theControl: ControlRef);
  332.     {$IFC NOT GENERATINGCFM}
  333.     INLINE $A96D;
  334.     {$ENDC}
  335. PROCEDURE UpdateControls(theWindow: WindowRef; updateRegion: RgnHandle);
  336.     {$IFC NOT GENERATINGCFM}
  337.     INLINE $A953;
  338.     {$ENDC}
  339. {_________________________________________________________________________________________________________}
  340. {    }
  341. { • CONTROL HIGHLIGHT API'S}
  342. {}
  343. {_________________________________________________________________________________________________________}
  344. PROCEDURE HiliteControl(theControl: ControlRef; hiliteState: ControlPartCode);
  345.     {$IFC NOT GENERATINGCFM}
  346.     INLINE $A95D;
  347.     {$ENDC}
  348. FUNCTION TrackControl(theControl: ControlRef; thePoint: Point; actionProc: ControlActionUPP): ControlPartCode;
  349.     {$IFC NOT GENERATINGCFM}
  350.     INLINE $A968;
  351.     {$ENDC}
  352. PROCEDURE DragControl(theControl: ControlRef; startPoint: Point; {CONST}VAR limitRect: Rect; {CONST}VAR slopRect: Rect; axis: DragConstraint);
  353.     {$IFC NOT GENERATINGCFM}
  354.     INLINE $A967;
  355.     {$ENDC}
  356. FUNCTION TestControl(theControl: ControlRef; thePoint: Point): ControlPartCode;
  357.     {$IFC NOT GENERATINGCFM}
  358.     INLINE $A966;
  359.     {$ENDC}
  360. FUNCTION FindControl(thePoint: Point; theWindow: WindowRef; VAR theControl: ControlRef): ControlPartCode;
  361.     {$IFC NOT GENERATINGCFM}
  362.     INLINE $A96C;
  363.     {$ENDC}
  364. {_________________________________________________________________________________________________________}
  365. {    }
  366. { • CONTROL MOVING/SIZING API'S}
  367. {}
  368. {_________________________________________________________________________________________________________}
  369. PROCEDURE MoveControl(theControl: ControlRef; h: SInt16; v: SInt16);
  370.     {$IFC NOT GENERATINGCFM}
  371.     INLINE $A959;
  372.     {$ENDC}
  373. PROCEDURE SizeControl(theControl: ControlRef; w: SInt16; h: SInt16);
  374.     {$IFC NOT GENERATINGCFM}
  375.     INLINE $A95C;
  376.     {$ENDC}
  377. {_________________________________________________________________________________________________________}
  378. {    }
  379. { • CONTROL TITLE API'S}
  380. {}
  381. {_________________________________________________________________________________________________________}
  382. PROCEDURE SetControlTitle(theControl: ControlRef; title: ConstStr255Param);
  383.     {$IFC NOT GENERATINGCFM}
  384.     INLINE $A95F;
  385.     {$ENDC}
  386. PROCEDURE GetControlTitle(theControl: ControlRef; VAR title: Str255);
  387.     {$IFC NOT GENERATINGCFM}
  388.     INLINE $A95E;
  389.     {$ENDC}
  390. {_________________________________________________________________________________________________________}
  391. {    }
  392. { • CONTROL VALUE, MIMIMUM, AND MAXIMUM API'S}
  393. {}
  394. {_________________________________________________________________________________________________________}
  395. FUNCTION GetControlValue(theControl: ControlRef): SInt16;
  396.     {$IFC NOT GENERATINGCFM}
  397.     INLINE $A960;
  398.     {$ENDC}
  399. PROCEDURE SetControlValue(theControl: ControlRef; newValue: SInt16);
  400.     {$IFC NOT GENERATINGCFM}
  401.     INLINE $A963;
  402.     {$ENDC}
  403. FUNCTION GetControlMinimum(theControl: ControlRef): SInt16;
  404.     {$IFC NOT GENERATINGCFM}
  405.     INLINE $A961;
  406.     {$ENDC}
  407. PROCEDURE SetControlMinimum(theControl: ControlRef; newMinimum: SInt16);
  408.     {$IFC NOT GENERATINGCFM}
  409.     INLINE $A964;
  410.     {$ENDC}
  411. FUNCTION GetControlMaximum(theControl: ControlRef): SInt16;
  412.     {$IFC NOT GENERATINGCFM}
  413.     INLINE $A962;
  414.     {$ENDC}
  415. PROCEDURE SetControlMaximum(theControl: ControlRef; newMaximum: SInt16);
  416.     {$IFC NOT GENERATINGCFM}
  417.     INLINE $A965;
  418.     {$ENDC}
  419. {_________________________________________________________________________________________________________}
  420. {    }
  421. { • CONTROL VARIANT AND WINDOW INFORMATION API'S}
  422. {}
  423. {_________________________________________________________________________________________________________}
  424. FUNCTION GetControlVariant(theControl: ControlRef): SInt16;
  425.     {$IFC NOT GENERATINGCFM}
  426.     INLINE $A809;
  427.     {$ENDC}
  428. {_________________________________________________________________________________________________________}
  429. {    }
  430. { • CONTROL ACTION PROC API'S}
  431. {}
  432. {_________________________________________________________________________________________________________}
  433. PROCEDURE SetControlAction(theControl: ControlRef; actionProc: ControlActionUPP);
  434.     {$IFC NOT GENERATINGCFM}
  435.     INLINE $A96B;
  436.     {$ENDC}
  437. FUNCTION GetControlAction(theControl: ControlRef): ControlActionUPP;
  438.     {$IFC NOT GENERATINGCFM}
  439.     INLINE $A96A;
  440.     {$ENDC}
  441. {_________________________________________________________________________________________________________}
  442. {    }
  443. { • CONTROL ACCESSOR API'S}
  444. {}
  445. {_________________________________________________________________________________________________________}
  446. PROCEDURE SetControlReference(theControl: ControlRef; data: SInt32);
  447.     {$IFC NOT GENERATINGCFM}
  448.     INLINE $A95B;
  449.     {$ENDC}
  450. FUNCTION GetControlReference(theControl: ControlRef): SInt32;
  451.     {$IFC NOT GENERATINGCFM}
  452.     INLINE $A95A;
  453.     {$ENDC}
  454. {_________________________________________________________________________________________________________}
  455. {    }
  456. { • PREPARE FOR THE COPLAND MACINTOSH OS NOW}
  457. {}
  458. {     The window control list is moving to the Control Manager.  In addition, to prepare for Copland, you}
  459. {     want to try to begin compiling with STRICT_CONTROLS and STRICT_WINDOWS turned on.  This makes the}
  460. {     ControlRecord and WindowRecord opaque and you will be unable to access the fields directly.  If you}
  461. {     need information from one of these fields, use one of the provided accessor functions.  For now,}
  462. {     the new accessor functions are provided as macros, but in Copland they will become true API entry}
  463. {      points.}
  464. {}
  465. {     So what does this all mean?  Replace all references to the window control list in the WindowRecord}
  466. {     with the macro below.  Then in the future when Copland interfaces are available, no source changes}
  467. {     will be required and the macro will automatically replaced with a call to the real API.}
  468. {}
  469. {     Please direct all questions regarding usuage to the TOOLBOX AppleLink address.}
  470. {}
  471. {     <<<< See Windows.h for more information >>>>>}
  472. {}
  473. {_________________________________________________________________________________________________________}
  474. {$IFC NOT STRICT_CONTROLS }
  475. FUNCTION GetAuxiliaryControlRecord(theControl: ControlRef; VAR acHndl: AuxCtlHandle): BOOLEAN;
  476.     {$IFC NOT GENERATINGCFM}
  477.     INLINE $AA44;
  478.     {$ENDC}
  479. {$ENDC}
  480. PROCEDURE SetControlColor(theControl: ControlRef; newColorTable: CCTabHandle);
  481.     {$IFC NOT GENERATINGCFM}
  482.     INLINE $AA43;
  483.     {$ENDC}
  484. {_________________________________________________________________________________________________________}
  485. {    }
  486. { • VALID 'CDEF' MESSAGES}
  487. {}
  488. {_________________________________________________________________________________________________________}
  489.     
  490. TYPE
  491.     ControlDefProcMessage = SInt16;
  492.  
  493.  
  494. CONST
  495.     drawCntl                    = 0;
  496.     testCntl                    = 1;
  497.     calcCRgns                    = 2;
  498.     initCntl                    = 3;
  499.     dispCntl                    = 4;
  500.     posCntl                        = 5;
  501.     thumbCntl                    = 6;
  502.     dragCntl                    = 7;
  503.     autoTrack                    = 8;
  504.     calcCntlRgn                    = 10;
  505.     calcThumbRgn                = 11;
  506.     drawThumbOutline            = 12;
  507.  
  508. {_________________________________________________________________________________________________________}
  509. {    }
  510. { • MAIN ENTRY POINT FOR 'CDEF'}
  511. {}
  512. {_________________________________________________________________________________________________________}
  513. TYPE
  514.     ControlDefProcPtr = ProcPtr;  { FUNCTION ControlDef(varCode: SInt16; theControl: ControlRef; message: ControlDefProcMessage; param: SInt32): SInt32; }
  515.     ControlDefUPP = UniversalProcPtr;
  516.  
  517. CONST
  518.     uppControlDefProcInfo = $00003BB0; { FUNCTION (2 byte param, 4 byte param, 2 byte param, 4 byte param): 4 byte result; }
  519.  
  520. FUNCTION NewControlDefProc(userRoutine: ControlDefProcPtr): ControlDefUPP;
  521.     {$IFC NOT GENERATINGCFM }
  522.     INLINE $2E9F;
  523.     {$ENDC}
  524.  
  525. FUNCTION CallControlDefProc(varCode: SInt16; theControl: ControlRef; message: ControlDefProcMessage; param: SInt32; userRoutine: ControlDefUPP): SInt32;
  526.     {$IFC NOT GENERATINGCFM}
  527.     INLINE $205F, $4E90;
  528.     {$ENDC}
  529. {_________________________________________________________________________________________________________}
  530. {    }
  531. { • CONSTANTS FOR DRAWCNTL MESSAGE PASSED IN PARAM}
  532. {}
  533. {_________________________________________________________________________________________________________}
  534.  
  535. CONST
  536.     kDrawControlEntireControl    = 0;
  537.     kDrawControlIndicatorOnly    = 129;
  538.  
  539. {_________________________________________________________________________________________________________}
  540. {    }
  541. { • CONSTANTS FOR DRAGCNTL MESSAGE PASSED IN PARAM}
  542. {}
  543. {_________________________________________________________________________________________________________}
  544.     kDragControlEntireControl    = 0;
  545.     kDragControlIndicator        = 1;
  546.  
  547. {_________________________________________________________________________________________________________}
  548. {    }
  549. { • DRAG CONSTRAINT STRUCTURE PASSED IN PARAM FOR THUMBCNTL MESSAGE (IM I-332)}
  550. {}
  551. {_________________________________________________________________________________________________________}
  552.  
  553. TYPE
  554.     IndicatorDragConstraint = RECORD
  555.         limitRect:                Rect;
  556.         slopRect:                Rect;
  557.         axis:                    DragConstraint;
  558.     END;
  559.  
  560.     IndicatorDragConstraintPtr = ^IndicatorDragConstraint;
  561.     IndicatorDragConstraintHandle = ^IndicatorDragConstraintPtr;
  562.  
  563. {_________________________________________________________________________________________________________}
  564. {}
  565. { • OLD ROUTINE NAMES}
  566. {}
  567. {   These are provided for compatiblity with older source bases.  It is recommended to not use them since}
  568. {     they may removed from this interface file at any time.}
  569. {}
  570. {_________________________________________________________________________________________________________}
  571. {$IFC OLDROUTINENAMES }
  572.  
  573. CONST
  574.     useWFont                    = 8;
  575.  
  576.     inLabel                        = 1;
  577.     inMenu                        = 2;
  578.     inTriangle                    = 4;
  579.     inButton                    = 10;
  580.     inCheckBox                    = 11;
  581.     inUpButton                    = 20;
  582.     inDownButton                = 21;
  583.     inPageUp                    = 22;
  584.     inPageDown                    = 23;
  585.     inThumb                        = 129;
  586.  
  587.     kNoHiliteControlPart        = 0;
  588.     kInLabelControlPart            = 1;
  589.     kInMenuControlPart            = 2;
  590.     kInTriangleControlPart        = 4;
  591.     kInButtonControlPart        = 10;
  592.     kInCheckBoxControlPart        = 11;
  593.     kInUpButtonControlPart        = 20;
  594.     kInDownButtonControlPart    = 21;
  595.     kInPageUpControlPart        = 22;
  596.     kInPageDownControlPart        = 23;
  597.     kInIndicatorControlPart        = 129;
  598.     kReservedControlPart        = 254;
  599.     kControlInactiveControlPart    = 255;
  600.  
  601. {$ENDC}
  602. {$IFC OLDROUTINENAMES }
  603.  
  604. PROCEDURE SetCTitle(theControl: ControlRef; title: ConstStr255Param);
  605.     {$IFC NOT GENERATINGCFM}
  606.     INLINE $A95F;
  607.     {$ENDC}
  608. PROCEDURE GetCTitle(theControl: ControlRef; VAR title: Str255);
  609.     {$IFC NOT GENERATINGCFM}
  610.     INLINE $A95E;
  611.     {$ENDC}
  612. PROCEDURE UpdtControl(theWindow: WindowRef; updateRgn: RgnHandle);
  613.     {$IFC NOT GENERATINGCFM}
  614.     INLINE $A953;
  615.     {$ENDC}
  616. {$IFC NOT STRICT_CONTROLS }
  617. PROCEDURE SetCtlValue(theControl: ControlRef; theValue: INTEGER);
  618.     {$IFC NOT GENERATINGCFM}
  619.     INLINE $A963;
  620.     {$ENDC}
  621. FUNCTION GetCtlValue(theControl: ControlRef): INTEGER;
  622.     {$IFC NOT GENERATINGCFM}
  623.     INLINE $A960;
  624.     {$ENDC}
  625. PROCEDURE SetCtlMin(theControl: ControlRef; minValue: INTEGER);
  626.     {$IFC NOT GENERATINGCFM}
  627.     INLINE $A964;
  628.     {$ENDC}
  629. FUNCTION GetCtlMin(theControl: ControlRef): INTEGER;
  630.     {$IFC NOT GENERATINGCFM}
  631.     INLINE $A961;
  632.     {$ENDC}
  633. PROCEDURE SetCtlMax(theControl: ControlRef; maxValue: INTEGER);
  634.     {$IFC NOT GENERATINGCFM}
  635.     INLINE $A965;
  636.     {$ENDC}
  637. FUNCTION GetCtlMax(theControl: ControlRef): INTEGER;
  638.     {$IFC NOT GENERATINGCFM}
  639.     INLINE $A962;
  640.     {$ENDC}
  641. {$ENDC}
  642. PROCEDURE SetCRefCon(theControl: ControlRef; data: LONGINT);
  643.     {$IFC NOT GENERATINGCFM}
  644.     INLINE $A95B;
  645.     {$ENDC}
  646. FUNCTION GetCRefCon(theControl: ControlRef): LONGINT;
  647.     {$IFC NOT GENERATINGCFM}
  648.     INLINE $A95A;
  649.     {$ENDC}
  650. PROCEDURE SetCtlAction(theControl: ControlRef; actionProc: ControlActionUPP);
  651.     {$IFC NOT GENERATINGCFM}
  652.     INLINE $A96B;
  653.     {$ENDC}
  654. FUNCTION GetCtlAction(theControl: ControlRef): ControlActionUPP;
  655.     {$IFC NOT GENERATINGCFM}
  656.     INLINE $A96A;
  657.     {$ENDC}
  658. PROCEDURE SetCtlColor(theControl: ControlRef; newColorTable: CCTabHandle);
  659.     {$IFC NOT GENERATINGCFM}
  660.     INLINE $AA43;
  661.     {$ENDC}
  662. FUNCTION GetCVariant(theControl: ControlRef): INTEGER;
  663.     {$IFC NOT GENERATINGCFM}
  664.     INLINE $A809;
  665.     {$ENDC}
  666. {$ENDC}
  667.  
  668. {$ALIGN RESET}
  669. {$POP}
  670.  
  671. {$SETC UsingIncludes := ControlsIncludes}
  672.  
  673. {$ENDC} {__CONTROLS__}
  674.  
  675. {$IFC NOT UsingIncludes}
  676.  END.
  677. {$ENDC}
  678.